package com.hl.vcd.mapper;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hl.vcd.entity.Video;
import com.hl.vcd.entity.vo.VideoSearch;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author 朱炫达
 */
public interface VideoMapper extends BaseMapper<Video> {

    public List<Video> getTopVideoByLike(@Param("number") Integer number, @Param("type") Integer type);

    public List<Video> getTopVideoByPlay(@Param("number") Integer number);

    public IPage<VideoSearch> searchVideo(Page<VideoSearch> page,@Param(Constants.WRAPPER) QueryWrapper<VideoSearch> wrapper);
}
